#include<stdio.h>
#include<string.h>
int IsRound(char arr1[],char arr2[])
{
	if(strlen(arr1)!=strlen(arr2))
	{
		return 0;
	}
	char temp[256];
	strcpy(temp,arr2);
	strcat(temp,arr2);
	return strstr(temp,arr1)!=NULL; 	
}
int main()
{
	char arr1[]="AABCD";
	char arr2[]="BCDAA";
	printf("%d\n",IsRound(arr1,arr2));
} 
